<?php

$_pef->id_cliente = $_SESSION['idcliente'];
$socialDados	= $_pef->pegaPerfilCliente();
if($socialDados["nome"] == ""){ $socialDados["nome"] = $cliente["nome"];}

?>

<div id="social-commerce">
<form action="modulos/perfil/acoes.php" method="post">
<input  type="hidden" name="acao" value="editar"  />
<h4><?php print $cliente["nome"]; ?> &raquo; Editar perfil</h4> 
<table width="100%" border="0" cellspacing="5" cellpadding="5" bgcolor="#F2F2F2" style="border:solid 1px #E0E0E0">
  <tr>
    <td align="right" valign="top"><strong>Nome de exibi&ccedil;&atilde;o:</strong></td>
    <td><input name="nome" type="text" class="inputCadastro" value="<?php print $socialDados["nome"]; ?>" size="53" id="nome" /></td>
  </tr>
  <tr>
    <td align="right" valign="top"><strong>Midias sociais:</strong></td>
    <td><table width="100%" border="0" cellspacing="2" cellpadding="2">
      <tr>
          <td width="3%"><img src="../../images/social-perfil/facebook.png" width="16" height="16" /></td>
          <td width="97%"><input name="facebook" type="text" class="inputCadastro" value="<?php print $socialDados["facebook"] ?>" size="53" id="facebook" style="width:40%" /></td>
        </tr>
        <tr>
          <td><img src="../../images/social-perfil/msn.png" width="16" height="16" /></td>
          <td><input name="msn" type="text" class="inputCadastro" value="<?php print $socialDados["msn"] ?>" size="53" id="nome3" style="width:40%"/></td>
        </tr>
        <tr>
          <td><img src="../../images/social-perfil/socialmedia.png" width="16" height="16" /></td>
          <td><input name="twitter" type="text" class="inputCadastro" value="<?php print $socialDados["twitter"] ?>" size="53" id="nome4" style="width:40%"/></td>
        </tr>
</table></td>
  </tr>
  <tr>
    <td align="right" valign="top"><strong>WebSite/Blog:</strong></td>
    <td><input name="website" type="text" class="inputCadastro" value="<?php print $socialDados["website"] ?>" size="53" id="nome5" /></td>
  </tr>
  <tr>
    <td align="right" valign="top"><strong>Interesse:</strong></td>
    <td>
    
    <ul id="interesses">
    <?php 
	$DadosInt	= $socialDados["interesse"];
	$DadosInt	= explode("#",$DadosInt);
    $interesses	= $_int->lista(false,false,false);
	foreach($interesses as $inter){
	$InteresseBusca = array_search($inter["id"], $DadosInt);
	if($InteresseBusca){ $checked = "checked";}else{ $checked = "";}
    ?>
		<li><input name="interesse[]" type="checkbox" value="<?php print $inter["id"]?>" <?php print $checked; ?>/><?php print utf8_encode($inter["titulo"])?></li>
    <?php }?>    
    </ul>
    
    </td>
  </tr>
  <tr>
    <td width="17%" align="right" valign="top"><b>Sobre mim:</b><br /></td>
    <td width="83%">
    
   <div> 
   <textarea onFocus="javascript:$(this).fadeIn(3000,function(){$(this).attr('rows',20)});" onBlur="javascript:$('#SobreUser').attr('rows',5);"  name="sobre" id="SobreUser" cols="40" rows="5" class="inputCadastro"><?php print $socialDados["sobre"] ?></textarea></div>
    </td>
  </tr>
  <tr>
    <td align="right" valign="top">&nbsp;</td>
    <td><input style="cursor:pointer" type="submit" class="butao_sub" value="Salvar altera&ccedil;&atilde;o" onclick="javascript: if(confirm('Deseja realmente alterar seu perfil?')){ return true; }else{ return false; };" /></td>
  </tr>
  <tr>
    <td align="right" valign="top">&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>

<div style="clear:both">&nbsp;</div>

</form></div>